Skip to content

[Main]<ImporteTAIReglasLocalizacion> node should have negative sign in the SII XML for Sales Credit Memos under One-Stop-Shop regime in the Spanish version - #10230

Open
Shikhverma wants to merge 1 commit into
mainfrom
bugs/Bug-642137-NodeShudhaveNegSigninSIIXMLfor-SalesCrMemunderOneStopShopregimeinESvers
Open

[Main]<ImporteTAIReglasLocalizacion> node should have negative sign in the SII XML for Sales Credit Memos under One-Stop-Shop regime in the Spanish version#10230
Shikhverma wants to merge 1 commit into
mainfrom
bugs/Bug-642137-NodeShudhaveNegSigninSIIXMLfor-SalesCrMemunderOneStopShopregimeinESvers

Conversation

@Shikhverma

@Shikhverma Shikhverma commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Bug 642137: [Master][all-e] node should have negative sign in the SII XML for Sales Credit Memos under One-Stop-Shop regime in the Spanish version.

Fixes AB#642137

@github-actions github-actions Bot added the Finance GitHub request for Finance area label Aug 13, 2026
@github-actions github-actions Bot added this to the Version 29.0 milestone Aug 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

⚠️ Stale Status Check Deleted

The Pull Request Build workflow run for this PR was older than 72 hours and has been deleted.

📋 Why was it deleted?

Status checks that are too old may no longer reflect the current state of the target branch. To ensure this PR is validated against the latest code and passes up-to-date checks, a fresh build is required.


🔄 How to trigger a new status check:

  1. 📤 Push a new commit to the PR branch, or
  2. 🔁 Close and reopen the PR

This will automatically trigger a new Pull Request Build workflow run.

@Shikhverma
Shikhverma marked this pull request as ready for review August 18, 2026 08:52
@Shikhverma
Shikhverma requested a review from a team August 18, 2026 08:52
@alexei-dobriansky

Copy link
Copy Markdown
Contributor

Agentic PR Review - Round 1

Recommendation: Accept

What this PR does

The PR fixes Bug 642137 for the Spanish SII XML: ImporteTAIReglasLocalizacion must be negative for sales credit memos under the One-Stop-Shop regime. The change keeps invoices positive, makes credit memos negative in the shared One-Stop-Shop amount buffer, and covers both normal and corrective credit memo flows.

The fix is targeted. HandleNonTaxableVATEntries and HandleReplacementNonTaxableVATEntries now pass the customer ledger entry document type into UpdateAmountBufferWithOneStopShop, and only credit memos use -Abs(TempVATEntry.Base). The surrounding export code still writes the same node only when One-Stop-Shop VAT entries exist, so the change addresses the sign without changing node selection or normal VAT handling.

Suggestions

None.

Risk assessment and necessity

Risk: This is a tax reporting path in SIIXMLCreator.Codeunit.al, so a wrong sign can produce incorrect SII XML for posted sales credit memos. The code change is narrow: it only changes the One-Stop-Shop non-taxable amount added to ImporteTAIReglasLocalizacion; it does not add events, change public signatures, or alter purchase/service logic. The updated tests cover invoices staying positive, credit memos becoming negative, replacement credit memos, and the specific corrective R5 credit memo scenario.

Necessity: The linked bug and PR title describe a concrete reporting defect. Without the change, sales credit memo XML under One-Stop-Shop can report the amount with the invoice sign. The scope matches that defect and is small enough for a bug fix.


[AI-PR-REVIEW] version=1 promptVersion=2 system=github pr=10230 round=1 by=alexei-dobriansky at=2026-08-18T13:07:32Z lastSha=1b885f6ca5f9eac23f750c4b0003774b06ef6211 reviewKey=dade0a73141eff24d2c04093bdb60ed01ace63dca72b430ff87df6b8be04c6db suggestions=none

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Finance GitHub request for Finance area

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants